package com.hongying.luoxinjie;

import java.text.SimpleDateFormat;
import java.util.Date;

public class DateUtils {
    /**
     * 格式化日期
     * @param dateDate
     * @param pattern
     * @return
     */
    public static String dateToStr(Date dateDate, String pattern) {
        SimpleDateFormat sdf = new SimpleDateFormat(pattern);
        return sdf.format(dateDate);
    }
}
